home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / p_man / cat3 / Xi / XGrabDevice.z / XGrabDevice
Encoding:
Text File  |  1998-10-30  |  11.0 KB  |  199 lines

  1.  
  2.  
  3.  
  4.      XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))  XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))   XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.           XGrabDevice, XUngrabDevice - grab/release the specified
  10.           extension device
  11.  
  12.      SSSSYYYYNNNNTTTTAAAAXXXX
  13.           iiiinnnntttt XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((_d_i_s_p_l_a_y,,,, _d_e_v_i_c_e,,,, _g_r_a_b__w_i_n_d_o_w,,,, _o_w_n_e_r__e_v_e_n_t_s,,,, _e_v_e_n_t__c_o_u_n_t,,,, _e_v_e_n_t__l_i_s_t,,,,
  14.           _t_h_i_s__d_e_v_i_c_e__m_o_d_e,,,, _o_t_h_e_r__d_e_v_i_c_e_s__m_o_d_e,,,, _t_i_m_e))))
  15.                 DDDDiiiissssppppllllaaaayyyy ****_d_i_s_p_l_a_y;;;;
  16.                 XXXXDDDDeeeevvvviiiicccceeee ****_d_e_v_i_c_e;;;;
  17.                 WWWWiiiinnnnddddoooowwww _g_r_a_b__w_i_n_d_o_w;;;;
  18.                 BBBBoooooooollll _o_w_n_e_r__e_v_e_n_t_s;;;;
  19.                 iiiinnnntttt _e_v_e_n_t__c_o_u_n_t;;;;
  20.                 XXXXEEEEvvvveeeennnnttttCCCCllllaaaassssssss ****_e_v_e_n_t__l_i_s_t;;;;
  21.                 iiiinnnntttt _t_h_i_s__d_e_v_i_c_e__m_o_d_e,,,, _o_t_h_e_r__d_e_v_i_c_e_s__m_o_d_e;;;;
  22.                 TTTTiiiimmmmeeee _t_i_m_e;;;;
  23.  
  24.           XXXXUUUUnnnnggggrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((_d_i_s_p_l_a_y,,,, _d_e_v_i_c_e,,,, _t_i_m_e))))
  25.                 DDDDiiiissssppppllllaaaayyyy ****_d_i_s_p_l_a_y;;;;
  26.                 XXXXDDDDeeeevvvviiiicccceeee ****_d_e_v_i_c_e;;;;
  27.                 TTTTiiiimmmmeeee _t_i_m_e;;;;
  28.  
  29.  
  30.      AAAARRRRGGGGUUUUMMMMEEEENNNNTTTTSSSS
  31.           _d_i_s_p_l_a_y     Specifies the connection to the X server.
  32.  
  33.           _d_e_v_i_c_e      Specifies the device to be grabbed or released.
  34.  
  35.           _g_r_a_b__w_i_n_d_o_w Specifies the id of a window to be associated
  36.                       with the device.
  37.  
  38.           _o_w_n_e_r__e_v_e_n_t_s
  39.                       Specifies a Boolean value that indicates whether
  40.                       the events from the device are to be reported as
  41.                       usual or reported with respect to the grab
  42.                       window if selected by the event list.
  43.  
  44.           _e_v_e_n_t__c_o_u_n_t Specifies the number of elements in the
  45.                       event_list array.
  46.  
  47.           _e_v_e_n_t__l_i_s_t  Specifies a pointer to a list of event classes
  48.                       that indicates which events the client wishes to
  49.                       receive.  These event classes must have been
  50.                       obtained specifying the device being grabbed.
  51.  
  52.           _t_h_i_s__d_e_v_i_c_e__m_o_d_e
  53.                       Specifies further processing of events from this
  54.                       device.  You can pass _G_r_a_b_M_o_d_e_S_y_n_c or
  55.                       _G_r_a_b_M_o_d_e_A_s_y_n_c.
  56.  
  57.           _o_t_h_e_r__d_e_v_i_c_e_s__m_o_d_e
  58.                       Specifies further processing of events from
  59.                       other devices.  You can pass _G_r_a_b_M_o_d_e_S_y_n_c or
  60.  
  61.  
  62.  
  63.      Page 1                                          (printed 4/30/98)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))  XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))   XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))
  71.  
  72.  
  73.  
  74.                       _G_r_a_b_M_o_d_e_A_s_y_n_c.
  75.  
  76.           _t_i_m_e        Specifies the time.  You can pass either a
  77.                       timestamp or _C_u_r_r_e_n_t_T_i_m_e.
  78.  
  79.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  80.           The _X_G_r_a_b_D_e_v_i_c_e request actively grabs control of the device
  81.           and generates _D_e_v_i_c_e_F_o_c_u_s_I_n and _D_e_v_i_c_e_F_o_c_u_s_O_u_t events.
  82.           Further device events are reported only to the grabbing
  83.           client.  _X_G_r_a_b_D_e_v_i_c_e overrides any active device grab by
  84.           this client.  event_list is a pointer to a list of event
  85.           classes.  This list indicates which events the client wishes
  86.           to receive while the grab is active.  If owner_events is
  87.           _F_a_l_s_e , all generated device events are reported with
  88.           respect to grab_window if selected.  If owner_events is _T_r_u_e
  89.           and if a generated device event would normally be reported
  90.           to this client, it is reported normally; otherwise, the
  91.           event is reported with respect to the grab_window, and is
  92.           only reported if specified in the event_list.
  93.  
  94.           If the this_device_mode argument is _G_r_a_b_M_o_d_e_A_s_y_n_c , device
  95.           event processing continues as usual. If the device is
  96.           currently frozen by this client, then processing of device
  97.           events is resumed.  If the this_device_mode  argument is
  98.           _G_r_a_b_M_o_d_e_S_y_n_c , the state of the device (as seen by client
  99.           applications) appears to freeze, and the X server generates
  100.           no further device events until the grabbing client issues a
  101.           releasing _X_A_l_l_o_w_D_e_v_i_c_e_E_v_e_n_t_s call or until the device grab
  102.           is released.  Actual device changes are not lost while the
  103.           device is frozen; they are simply queued in the server for
  104.           later processing.
  105.  
  106.           If other_devices_mode is _G_r_a_b_M_o_d_e_A_s_y_n_c , processing of
  107.           events from other devices is unaffected by activation of the
  108.           grab. If other_devices_mode is _G_r_a_b_M_o_d_e_S_y_n_c, the state of
  109.           all devices except the grabbed device
  110.            (as seen by client applications) appears to freeze, and the
  111.           X server generates no further events from those devices
  112.           until the grabbing client issues a releasing
  113.           _X_A_l_l_o_w_D_e_v_i_c_e_E_v_e_n_t_s call or until the device grab is
  114.           released.  Actual events are not lost while the devices are
  115.           frozen; they are simply queued in the server for later
  116.           processing.
  117.  
  118.           If the device is actively grabbed by some other client,
  119.           _X_G_r_a_b_D_e_v_i_c_e fails and returns _A_l_r_e_a_d_y_G_r_a_b_b_e_d.  If
  120.           grab_window is not viewable, it fails and returns
  121.           _G_r_a_b_N_o_t_V_i_e_w_a_b_l_e.  If the device is frozen by an active grab
  122.           of another client, it fails and returns _G_r_a_b_F_r_o_z_e_n.  If the
  123.           specified time is earlier than the last-device-grab time or
  124.           later than the current X server time, it fails and returns
  125.           _G_r_a_b_I_n_v_a_l_i_d_T_i_m_e.  Otherwise, the last-device-grab time is
  126.  
  127.  
  128.  
  129.      Page 2                                          (printed 4/30/98)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))  XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))   XXXXGGGGrrrraaaabbbbDDDDeeeevvvviiiicccceeee((((3333XXXX11111111))))
  137.  
  138.  
  139.  
  140.           set to the specified time ( _C_u_r_r_e_n_t_T_i_m_e is replaced by the
  141.           current X server time).
  142.  
  143.           If a grabbed device is closed by a client while an active
  144.           grab by that client is in effect, the active grab is
  145.           released.  If the device is frozen only by an active grab of
  146.           the requesting client, it is thawed.
  147.  
  148.           _X_G_r_a_b_D_e_v_i_c_e can generate _B_a_d_C_l_a_s_s, _B_a_d_D_e_v_i_c_e, _B_a_d_V_a_l_u_e, and
  149.           _B_a_d_W_i_n_d_o_w errors.
  150.  
  151.           The _X_U_n_g_r_a_b_D_e_v_i_c_e request releases the device and any queued
  152.           events if this client has it actively grabbed from either
  153.           _X_G_r_a_b_D_e_v_i_c_e or _X_G_r_a_b_D_e_v_i_c_e_K_e_y.  If other devices are frozen
  154.           by the grab, _X_U_n_g_r_a_b_D_e_v_i_c_e thaws them.  _X_U_n_g_r_a_b_D_e_v_i_c_e does
  155.           not release the device and any queued events if the
  156.           specified time is earlier than the last-device-grab time or
  157.           is later than the current X server time.  It also generates
  158.           _D_e_v_i_c_e_F_o_c_u_s_I_n and _D_e_v_i_c_e_F_o_c_u_s_O_u_t events.  The X server
  159.           automatically performs an _U_n_g_r_a_b_D_e_v_i_c_e request if the event
  160.           window for an active device grab becomes not viewable.
  161.  
  162.           _X_U_n_g_r_a_b_D_e_v_i_c_e can generate a _B_a_d_D_e_v_i_c_e error.
  163.  
  164.      DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  165.           _B_a_d_D_e_v_i_c_e   An invalid device was specified.  The specified
  166.                       device does not exist or has not been opened by
  167.                       this client via _X_O_p_e_n_I_n_p_u_t_D_e_v_i_c_e.  This error
  168.                       may also occur if the specified device is the X
  169.                       keyboard or X pointer device.
  170.  
  171.           _B_a_d_V_a_l_u_e    Some numeric value falls outside the range of
  172.                       values accepted by the request.  Unless a
  173.                       specific range is specified for an argument, the
  174.                       full range defined by the argument's type is
  175.                       accepted.  Any argument defined as a set of
  176.                       alternatives can generate this error.
  177.  
  178.           _B_a_d_W_i_n_d_o_w   A value for a Window argument does not name a
  179.                       defined Window.
  180.  
  181.      SSSSEEEEEEEE AAAALLLLSSSSOOOO
  182.           XAllowDeviceEvents(3X), XGrabDeviceButton(3X),
  183.           XGrabDeviceKey(3X),
  184.           _P_r_o_g_r_a_m_m_i_n_g _W_i_t_h _X_l_i_b
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.      Page 3                                          (printed 4/30/98)
  196.  
  197.  
  198.  
  199.